home *** CD-ROM | disk | FTP | other *** search
/ ftp.mactech.com 2010 / ftp.mactech.com.tar / ftp.mactech.com / util / Mac F2C 1.3.sit / Mac F2C 1.3 / Test Project ƒ / test.68K.make < prev    next >
Text File  |  1995-11-18  |  2KB  |  80 lines

  1. #   File:       test.68K.make
  2. #   Target:     test.68K
  3. #   Sources:    test.c
  4.  
  5. Makefile = test.68K.make
  6.  
  7. object_folder = ":objects_68K:"
  8. fsource =    test.f 
  9.             
  10. csource =    F2Cmain.c
  11.  
  12. fobjs     =    {object_folder}test.f.o  
  13.             
  14. cobjs    =    {object_folder}F2Cmain.c.o 
  15.  
  16.  
  17. objects =    {fobjs} ∂
  18.             {cobjs}
  19.  
  20. Segment.1        =    "{object_folder}F2Cmain.c.o" ∂
  21.                     "{object_folder}test.f.o"
  22.  
  23. Segment.2        =        "{MW68KLibraries}MPW ANSI (4i/8d) C.68K.Lib" ∂
  24.                         "{MW68KLibraries}MacOS.Lib" ∂
  25.                         "{MW68KLibraries}MathLib68K (4i/8d).Lib" ∂
  26.                         "{MW68KLibraries}ToolLibs.o.lib"
  27.  
  28.  
  29. Segment.3        =    "{F2CLibraries}"libF77.68K ∂
  30.                     "{F2CLibraries}"libI77.68K
  31.  
  32. C            =    MWC68K
  33. COptions    =   -mapcr -model far -align mac68k -intsize 4 -dsize 64 -d MPW_CW_F2C -w off
  34. F2C            =    f2c
  35. #F2COptions    =    -f -!i8 -A -P -a -E -ec -!R -r8 -s -w66 -Nq150 -Nx200 -Ns801 -Nc20 -Nn401 -NL200 -NC99 -Nl256 
  36. F2COptions    =    -f -!i8 -A -a -E -ec -!R -r8 -w66
  37. Link        =    MWLink68K
  38. LinkOptions    =    -d -c 'MPS ' -t 'MPST' -fastlink off -mpwtool -model far -intsize 4
  39. test.68K  ƒƒ  {Makefile} {Objects}
  40.     {Link} {LinkOptions} ∂
  41.         -sb "Your Code"        -ra "Your Code"=resPreload,resProtected,resLocked ∂
  42.         {Segment.1} ∂
  43.         -sb "CW libs"        -ra "CW libs"=resProtected,resPurgeable ∂
  44.         {Segment.2} ∂
  45.         -sb "F2C libs"        -ra "F2C libs"=resProtected,resPurgeable ∂
  46.         {Segment.3} ∂
  47.         -o test.68K
  48.  
  49. .f.o    ƒ    .f
  50.     {F2C} {F2COptions} {Default}.f     #compile the fortran and then compile the resulting C file.
  51.     setfile -t "TEXT" -c "MPS " {default}.c
  52.     {C} {default}.c {COptions} ∂
  53.     -o {targDir}{default}.f.o
  54.  
  55.  
  56. .c.o ƒ .c
  57.     {C} {default}.c {COptions} ∂
  58.     -o {targDir}{default}.c.o
  59.  
  60.  
  61. # If your FORTRAN code has common blocks add common.c.o to the cobjs list 
  62. # and then this rule should take care of it
  63. common.c    ƒ    {fobjs}
  64.     setfile -t "TEXT" -c "MPS " ?+_com.c
  65.     catenate ?+_com.c > {Targ}            #This puts all the common block files into one file for compiling.
  66.                                         #The wild card lets us add common blocks to the fortran code
  67.                                         #without having to change the makefile!  The common block files all
  68.                                         #end with _com.c
  69.  
  70. {objects}    ƒ    {Makefile}        #do a full rebuild if the makefile changes
  71.  
  72. {object_folder}    ƒ :
  73.  
  74. {object_folder}test.f.o  ƒ test.f
  75.             
  76. {object_folder}F2Cmain.c.o    ƒ F2Cmain.c
  77.  
  78. # makefile end
  79.  
  80.